/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: HP
 * Date: 2023 -05 -15
 * Time: 15:59
 */
class InvalidTriangleException extends Exception {
    private final double s1;
    private final double s2;
    private final double s3;

    public InvalidTriangleException(double s1, double s2, double s3) {
        this.s1 = s1;
        this.s2 = s2;
        this.s3 = s3;
    }

    @Override
    public String toString() {
        return "这三条边无法构成合法的三角形: " + s1 + ", " + s2 + ", " + s3 ;
    }
}